/* Define to prevent recursive inclusion -------------------------------------*/
#ifndef __RF_H__
#define __RF_H__

/* Includes ------------------------------------------------------------------*/
#include "stm8s.h"

/* Exported types ------------------------------------------------------------*/
/* Exported constants --------------------------------------------------------*/
#define RF_PORT    (GPIOD)
#define RF_PINS    (GPIO_PIN_4)

typedef enum
{
    NORMAL,
    ENTER_LEARN_RF,
    LEARN_RF_FOR_RELAY1,
    LEARN_RF_FOR_RELAY2,
    LEARN_RF_FOR_RELAY3,
    LEARN_RF_FOR_RELAY4,
    LEARN_RF_FOR_RELAY5,
    LEARN_RF_FOR_RELAY6,
    QUIT_LEARN_RF
} eRfMode;

/* Exported macro ------------------------------------------------------------*/
/* Exported functions ------------------------------------------------------- */
extern U8 s_ButtonMapping[];

void Rf_Init(void);
eRfMode Rf_GetMode( void );
void Rf_SetMode( eRfMode iMode );
void Rf_RunOne(void);
void Rf_SaveButtonMapping(void);

#endif /* __RF_H__ */

